package com.project.service.impl;

import com.project.bean.CommentBean;
import com.project.dao.ICommentDao;
import com.project.service.ICommentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@SuppressWarnings("all")
@Service
public class CommentServiceImpl implements ICommentService {
    @Autowired
    private ICommentDao dao;
    @Override
    public List<CommentBean> add(CommentBean comment, Integer themeId) {
        dao.add(comment);
        return dao.findByTheme(themeId);
    }
}
